<?php
/* 
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

if(!defined('TinyFW')) exit('Access denied!');

class tfFormLabel extends tfFormElement {


    public function  __construct($name='', $id='', $caption='', $value='', $attr_arr='') {
        $this->setName($name);
        $this->setId($id);
        $this->setCaption($caption);
        $this->setValue($value);
        if(!empty($attr_arr)) {
            $this->setAttr($attr_arr);
        }
    }

    public function render() {
        return "<label name='" . $this->getName() . "' id='" . $this->getId() . "' " . $this->getAttrStr() . " >" . $this->getCaption() . "</label>\r\n";
    }

    /*
    public function  __toString() {
        $this->render();
    }
    */


}

?>
